<div id="result">
    <h5>Edit <?php echo $this->data['Paymentmethod']['methodname']; ?> Configuration.</h5>
    <form method="post" id="add_category" action="<?php echo Configure::read('base_url') . "paymentmethods/edit"; ?>">
        <?php echo $this->Form->input('id', array('type' => 'hidden','value' => $this->data['Paymentmethod']['id'])); ?>
        <table cellspacing="0" id="mytable">
            <tbody>
                <tr>
                    <td colspan="2">
                        <table width="100%" border="0" cellspacing="0" cellpadding="0">                            
                                <tr>
                                    <td align="right"><br />API/Merchant User :</td>	
                                    <td  align="left"><br />
                                        <?php echo $this->Form->input('apiuser', array('label' => false, 'size' => 64, 'class' => "required", 'value' => $this->data['Paymentmethod']['apiuser'], 'title' => "API User can not empty.")); ?>			
                                    </td>		
                                </tr>
                                <tr>					
                                    <td align="right"><br />API/Merchant Signature :</td>	
                                    <td align="left"><br />
                                        <?php echo $this->Form->input('apisigniture', array('label' => false, 'size' => 64, 'class' => "required", 'value' => $this->data['Paymentmethod']['apisigniture'], 'title' => "API Password can not empty.")); ?>
                                    </td>		
                                </tr>
                            <tr>					
                                    <td align="right"><br />API/Merchant Password :</td>	
                                    <td align="left"><br />
                            <?php echo $this->Form->input('apipass', array('label' => false, 'size' => 64, 'class' => "required", 'value' => $this->data['Paymentmethod']['apipass'], 'title' => "API Password can not empty.")); ?>
                                    </td>		
                            </tr>
                            <tr>						
                                <td align="right"><br />Status :</td>	
                                <td align="left"><br />
                                    <?php
                                    $options = array('live' => 'live', 'demo' => 'demo');
                                    echo $this->Form->select('state', $options, array('selected' => $this->data['Paymentmethod']['state']), array('empty' => false));
                                    ?>
                                </td>	
                            </tr>
                            <tr> 
                                <td align="right"></td>
                                <td align="left" width="347"><br /><input type="submit" style="background:#73AE0B; color:#fff; font-size:14px;" name="button" id="button" value="Submit" /></td>    
                            </tr></table></td>
                </tr>
            </tbody></table>
    </form>
</div>
<?php echo $html->script(array("jquery.min.js", "jquery.form.js", "jquery.validate.js")); ?>
<script type="text/javascript">
    jQuery(document).ready(function(){ 
        var v = jQuery("#add_category").validate({
            submitHandler: function(form) {
                jQuery(form).ajaxSubmit({
                    target: "#result"
                });
            }
        });
    });
</script>